package com.second.mapper;

import com.second.model.dto.classify.FShopAndFTypeDto;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;
@Repository
@Transactional
public interface FShopAndFTypeMapper {
    //根据菜品类型查询
    @Select("select s.*,t.type from f_shop s join f_type t on s.id=t.shop_id where t.type=#{value}")
    List<FShopAndFTypeDto> findByType(Integer type);
//    @Select("select s.*,t.type from f_shop s join f_type t on s.id=t.shop_id where t.shopId=#{value}")
//    List<FShopAndFTypeDto> findByShopId(Integer id);
}
